﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="receive.aspx.cs" Inherits="AnyOffice.general.report.info.receive" %>

<%@ Reference Page="~/general/index.aspx" %>
<%@Register TagPrefix="Webdiver" Namespace="Webdiver" Assembly="AspnetPager" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title></title>
		
		<script>
function open_week(report_id)
{
// URL="read_week.aspx?report_id="+report_id;
// myleft=(screen.availWidth-500)/2;
// mytop=150
// mywidth=600;
// myheight=500;
// window.open(URL,"read_report","height="+myheight+",width="+mywidth+",status=1,toolbar=no,menubar=no,location=no,scrollbars=yes,top="+mytop+",left="+myleft+",resizable=yes");

 var mwidth = "600";
 var mheight = "450";
 var loc_x = parseInt((window.screen.width - mwidth) / 2);
 var loc_y = parseInt((window.screen.height - mwidth) / 2);

 var _oParameter = new Object();
 _oParameter.dialogTitle = "项目进度";
 _oParameter.openFile = "read_week.aspx?report_id=" + report_id + "&num=" + Math.random();

 window.showModalDialog('shDialog.htm', _oParameter, 'dialogHeight:' + mheight + 'px;dialogWidth:' + mwidth + 'px;dialogLeft:' + loc_x + ';dialogTop:' + loc_y + ';help:no;status:no;scroll:yes;titlebar:no;toolbar:no');
  








}

function open_month(report_id)
{
// URL="read_month.aspx?report_id="+report_id;
// myleft=(screen.availWidth-500)/2;
// mytop=150
// mywidth=600;
// myheight=500;
// window.open(URL,"read_report","height="+myheight+",width="+mywidth+",status=1,toolbar=no,menubar=no,location=no,scrollbars=yes,top="+mytop+",left="+myleft+",resizable=yes");

 var mwidth = "600";
 var mheight = "450";
 var loc_x = parseInt((window.screen.width - mwidth) / 2);
 var loc_y = parseInt((window.screen.height - mwidth) / 2);

 var _oParameter = new Object();
 _oParameter.dialogTitle = "项目进度";
 _oParameter.openFile = "read_month.aspx?report_id=" + report_id + "&num=" + Math.random();

 window.showModalDialog('shDialog.htm', _oParameter, 'dialogHeight:' + mheight + 'px;dialogWidth:' + mwidth + 'px;dialogLeft:' + loc_x + ';dialogTop:' + loc_y + ';help:no;status:no;scroll:yes;titlebar:no;toolbar:no');
  







}

function open_year(report_id) {
//    URL = "read_year.aspx?report_id=" + report_id;
//    myleft = (screen.availWidth - 500) / 2;
//    mytop = 150
//    mywidth = 600;
//    myheight = 500;
//    window.open(URL, "read_report", "height=" + myheight + ",width=" + mywidth + ",status=1,toolbar=no,menubar=no,location=no,scrollbars=yes,top=" + mytop + ",left=" + myleft + ",resizable=yes");

    var mwidth = "600";
    var mheight = "450";
    var loc_x = parseInt((window.screen.width - mwidth) / 2);
    var loc_y = parseInt((window.screen.height - mwidth) / 2);

    var _oParameter = new Object();
    _oParameter.dialogTitle = "项目进度";
    _oParameter.openFile = "read_year.aspx?report_id=" + report_id + "&num=" + Math.random();

    window.showModalDialog('shDialog.htm', _oParameter, 'dialogHeight:' + mheight + 'px;dialogWidth:' + mwidth + 'px;dialogLeft:' + loc_x + ';dialogTop:' + loc_y + ';help:no;status:no;scroll:yes;titlebar:no;toolbar:no');
   

}

function delete_week(report_id,page)
{
 msg='确认要删除该项周报么？';
 if(window.confirm(msg))
 {
  URL="delete.aspx?report_id=" + report_id + "&page=" + page;
  window.location=URL;
 }
}


function delete_month(report_id,page)
{
 msg='确认要删除该项月报么？';
 if(window.confirm(msg))
 {
  URL="delete.aspx?report_id=" + report_id + "&page=" + page;
  window.location=URL;
 }
}

</script>
	</HEAD>
	<body class="bodycolor" topmargin="5">
		<form id="Form1" method="post" runat="server">
         <div class="main_div">
			<table class="small" cellSpacing="0" cellPadding="3" width="100%" border="0">
				<tr>
					<td class="Big" width="40%"><img src="/images/notify_open.gif" align="absMiddle"><span class="big3">
							工作督办</span></td>
					<td width="20%">
						<asp:Literal id="litNavCount" runat="server"></asp:Literal>
					</td>
					<td width="40%">
						<asp:Literal id="litNavPager" runat="server"></asp:Literal>
					</td>
				</tr>
			</table>
			<asp:panel id="pnlMain" runat="server">
				<BR>
				<asp:Repeater id="rptReport" runat="server">
					<HeaderTemplate>
						<table width="100%" cellSpacing="0" cellPadding="0" border="0" class="tab_pub" align="center">
							<tr class="TableHeader">
								<td nowrap align="center" width="30%">标题</td>
								<td nowrap align="center">类型</td>
								<td nowrap align="center">汇报人</td>
								<td nowrap align="center">汇报时间</td>								
								<td nowrap align="center">操作</td>
							</tr>
					</HeaderTemplate>
					<ItemTemplate>
						<tr class="TableLine1">
							<td>
								<a href="javascript:<%#getJsNameByTypeID(Eval("Type").ToString())%>('<%#Eval("ReportId")%>');"><%#Eval("Title")%></a>
							</td>
							<td nowrap align="center"><%#getTypeNameByTypeID(Eval("Type").ToString())%></td>
							<td nowrap align="center"><u title="部门：<%#Eval("DeptName")%>" style="CURSOR:hand"><%#Eval("UserName")%></u></td>
							<td nowrap align="center"><%#Convert.ToDateTime(Eval("ReportTime").ToString()).ToString("yyyy-MM-dd")%></td>
							<td nowrap align="center">
								<a href="javascript:<%#Convert.ToInt32(Eval("Type")) == 1 ? "open_week" : "open_month"%>('<%#Eval("ReportId")%>');">点评</a>
							</td>						
						</tr>
					</ItemTemplate>	
					<AlternatingItemTemplate>
					<tr class="TableLine2">
							<td>
								<a href="javascript:<%#getJsNameByTypeID(Eval("Type").ToString())%>('<%#Eval("ReportId")%>');"><%#Eval("Title")%></a>
							</td>
							<td nowrap align="center"><%#getTypeNameByTypeID(Eval("Type").ToString())%></td>
							<td nowrap align="center"><u title="部门：<%#Eval("DeptName")%>" style="CURSOR:hand"><%#Eval("UserName")%></u></td>
							<td nowrap align="center"><%#Convert.ToDateTime(Eval("ReportTime").ToString()).ToString("yyyy-MM-dd")%></td>
							<td nowrap align="center">
								<a href="javascript:<%#Convert.ToInt32(Eval("Type")) == 1 ? "open_week" : "open_month"%>('<%#Eval("ReportId")%>');">点评</a>
							</td>						
						</tr>
					</AlternatingItemTemplate>				
					<FooterTemplate>
						</table>
					</FooterTemplate>
				</asp:Repeater>
				<TABLE width="100%" border="0">
					<TR>
						<TD>
							<Webdiver:AspNetPager id="AspNetPager1" runat="server" CssClass="small1" InputBoxClass="SmallInput" SubmitButtonClass="SmallButton"
								Font-Size="10pt" OnPageChanged="ChangePage" HorizontalAlign="Right" ShowCustomInfoSection="left" ShowInputBox="Always"
								SubmitButtonText="转到" NumericButtonTextFormatString="[{0}]" UrlPaging="True" CustomInfoSectionWidth="35%"
								PagingButtonSpacing="0" ImagePath="../images" ButtonImageNameExtension="n" CpiButtonImageNameExtension="r"
								DisabledButtonImageNameExtension="g" PageSize="10" AlwaysShow="True"></Webdiver:AspNetPager></TD>
					</TR>
				</TABLE>
			</asp:panel>
			<asp:literal id="litMessage" runat="server"></asp:literal>
            </div>
		</form>
	</body>
</HTML>
